package com.teemor.demo.spi;

import com.teemor.demo.spi.PrintService;

import java.util.ServiceLoader;

/**
 * @Description:
 * @author zhoulk
 * @date: 2020/3/31
 */
public class Application {
    public static void main(String[] args) {
        ServiceLoader<PrintService> serviceServiceLoader = ServiceLoader.load(PrintService.class);
        for (PrintService printService : serviceServiceLoader) {
            printService.printInfo();
        }
    }
}
